<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" />
		<title>万能许愿机</title>
		<link href="css/FengMain.css" rel="stylesheet" type="text/css" />
		<link href="css/bootstrap-4.4.1.css" rel="stylesheet" type="text/css" />
		<link href="css/layui.css" rel="stylesheet" type="text/css" />
		<link rel="stylesheet" type="text/css" href="assets/waifu.css" />
		<link rel="stylesheet" href="css/homeMain.css" type="text/css" />
		<script src="js/jquery-3.4.1.min.js" type="text/javascript"></script>
		<script src="js/bootstrap-4.4.1.js" type="text/javascript"></script>
	</head>
	<body>
		<span style="visibility: hidden;" id="up-span">up</span>
		<div class="container-fluid ">
			<div class="row justify-content-center">
				<div class="col-md-12 ">
					<nav class="navbar navbar-expand-lg navbar-light ">
						<a class="navbar-brand navFatherFontSize" href="#">YQYStudio</a>
						<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav"
						 aria-expanded="false" aria-label="Toggle navigation">
							<span class="navbar-toggler-icon"></span>
						</button>
						<div class="collapse navbar-collapse navFontSize justify-content-center" id="navbarNav">
							<ul class="navbar-nav justify-content-center">
								<li class="nav-item ">
									<a class="nav-link" href="index.html">主页</a>
								</li>
								<li class="nav-item">
									<a class="nav-link" href="stroe.html">仓库</a>
								</li>
								<li class="nav-item">
									<a class="nav-link" href="data.html">数据说明</a>
								</li>
								<li class="nav-item">
									<a class="nav-link" href="wannengdianshi.html">万能电视机</a>
								</li>
								<li class="nav-item">
									<a class="nav-link" href="other.html">关于我</a>
								</li>
								<li class="nav-item">
									<a class="nav-link" href="moban.html">template</a>
								</li>
							</ul>
						</div>
					</nav>
				</div>
			</div>
		</div>

		<div class="container" id="main_content">
			<div class="row">
				<div class="col-md-12 box pt-3">
					<div class="input-group mb-3">
						<input type="text" class="form-control" placeholder="键入轮次" v-model="sum_lun">
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">键入轮次</span>
						</div>
						<input type="text" class="form-control" placeholder="键入概率,1-1000000(0.00001-1),默认概率位1000(0.1)" v-model="ran">
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">键入概率</span>
						</div>
					</div>
					<div class="input-group mb-3">
						<input type="text" class="form-control" placeholder="概率极值(比如:100)" v-model="ran">
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">键入概率极值</span>
						</div>
						<input type="text" class="form-control" placeholder="概率底值(比如:1)" v-model="fixed_param">
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">键入概率底值</span>
						</div>
					</div>
					<div class="input-group mb-3">
						<input type="text" class="form-control" placeholder="键入保底轮次" v-model="cj_floors">
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">保底轮次</span>
						</div>
						<input type="text" class="form-control" disabled="disabled" placeholder="保底不算概率结果,计算原概率">
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">参数提示</span>
						</div>
					</div>

					<div class="input-group mb-3">
						<input type="text" class="form-control" placeholder="键入切割小数位" v-model="sub_str">
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">键入分割小数位</span>
						</div>
						<input type="text" class="form-control" disabled="disabled" v-model="sub_tips" placeholder="请输入有限位数">
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">小数位警示</span>
						</div>
					</div>
					
					

					<div class="input-group mt-2 mb-2">
						<button @click="ran_getResult" class="btn btn-outline-success form-control font-weight-bold">开始模拟</button>
						<button @click="clearArray" class="btn btn-outline-danger form-control font-weight-bold">清空概率表</button>
					</div>
					
					<!-- up表 -->
					<div class="input-group mb-3">
						<input type="text" class="form-control" placeholder="键入物品名称" v-model="user_list_name" >
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">键入名称</span>
						</div>
						<input type="text" class="form-control" placeholder="键入物品权重" v-model="user_list_weight" >
						<div class="input-group-append">
							<span class="input-group-text" id="basic-addon2">键入权重</span>
						</div>
					</div>
					<div class="input-group mb-3">
						<input type="text" class="form-control" v-model="user_list_tips" placeholder="运行正常" disabled="disabled">
					</div>
					<div class="input-group mt-2 mb-2">
						<button @click="addUserList"  class="btn btn-outline-success form-control font-weight-bold">加入up表</button>
						<button @click="clearUserList" class="btn btn-outline-danger form-control font-weight-bold">清空up表</button>
						<button @click="printTable" class="btn btn-outline-danger form-control font-weight-bold">打印</button>
					</div>
				</div>

				<div class="col-md-12 box pt-3 mt-3">
					<div class="text-center mb-2 navFontSize">up表</div>
					<table class="table table-hover text-center">
						<thead>
							<tr class="bg-dark text-white">
								<td>序列</td>
								<td>名称</td>
								<td>权重</td>
								<td>时间</td>
								<td>操作</td>
							</tr>
						</thead>
						<tbody>
							<tr v-for="(v,index) in user_list" :key="v">
								<td>{{index+1}}</td>
								<td>{{v.listName}}</td>
								<td>{{v.listWeight}}</td>
								<td>{{v.listDate}}</td>
								<td>
									<a class="btn btn-outline-secondary form-control " @click="delList(index)">删除</a>
								</td>
							</tr>
						</tbody>
					</table>
				</div>

				<!-- 概率表 -->
				<div class="col-md-12 box pt-3 mt-3">
					<div class="text-center mb-2 navFontSize">概率表</div>
					<table class="table table-hover text-center">
						<thead>
							<tr class="bg-dark text-white">
								<td>序列</td>
								<td>结果</td>
								<td>是否保底</td>
								<td>轮次概率</td>
								<td>总概率</td>
								<td>自定义概率</td>
								<td>轮次总数</td>
							</tr>
						</thead>
						<tbody>
							<tr v-for="(v,index) in param_array" :key="v">
								<td>{{v.index}}</td>
								<td :class="v.result?td_error:td_dark">{{v.result}}</td>
								<td :class="v.isfloor?td_error:td_dark">{{v.isfloor}}</td>
								<td>{{v.this_chance}}</td>
								<td>{{v.chances}}</td>
								<td>{{v.this_gailv}}</td>
								<td>{{v.sum}}</td>
							</tr>
						</tbody>
					</table>
				</div>


			</div>
		</div>

		<!-- 上下的 -->
		<div class="fixed-div-top text-center" id="cast">
			<!-- up -->
			
			<a href="#up-span">
				<div>
					顶
				</div>
			</a>
			
			<!-- bottpm -->
			<a href="#down-span">
				<div class="mt-3">
					底
				</div>
			</a>
		</div>

		<div class="waifu">
			<div class="waifu-tips"></div>
			<canvas id="live2d" width="280" height="250" class="live2d"></canvas>
			<div class="waifu-tool">
				<span class="fui-home"></span>
				<span class="fui-chat"></span>
				<span class="fui-eye"></span>
				<span class="fui-user"></span>
				<span class="fui-photo"></span>
				<span class="fui-info-circle"></span>
				<span class="fui-cross"></span>
			</div>
		</div>
		<span style="visibility: hidden;" id="down-span">down</span>
		<script src="js/vue.global.js" type="text/javascript"></script>
		<script src="js/homejs/main.js" type="text/javascript"></script>
		<script src="assets/waifu-tips.js"></script>
		<script src="assets/live2d.js"></script>
		<script type="text/javascript">
			initModel("assets/")
		</script>
	</body>
</html>
